import axios from "axios";
const config = require("./base");

// ======================用户===============================

export function _login(data) {
  return axios.post(config.api.login, data);
}
export function _register(data) {
  return axios.post(config.api.register, data);
}
export function _get_u() {
  return axios.get(config.api.get_u);
}

export function _add_u(data) {
  return axios.post(config.api.add_u, data);
}

export function _update_u(id, data) {
  return axios.post(config.api.update_u + `?id=${id}`, data);
}

export function _del_u(id) {
  return axios.get(config.api.del_u + `?id=${id}`);
}

// =====================映射表===============================

export function _get_map() {
  return axios.get(config.api.get_map);
}

export function _update_map(id, data) {
  return axios.post(config.api.update_map + `?id=${id}`, data);
}



// ==========================蒙古文===========================
export function _mgw1_dect(data) {
  return axios.post(config.api.mgw1_dect, data);
}
export function _mgw2_dect(data) {
  return axios.post(config.api.mgw2_dect, data);
}
export function _mgw3_dect(data) {
  return axios.post(config.api.mgw3_dect, data);
}
// ==========================满文===========================

export function _mw1_dect(data) {
  return axios.post(config.api.mw1_dect, data);
}
export function _mw2_dect(data) {
  return axios.post(config.api.mw2_dect, data);
}
export function _mw3_dect(data) {
  return axios.post(config.api.mw3_dect, data);
}
// ==========================托忒文===========================
export function _ttw1_dect(data) {
  return axios.post(config.api.ttw1_dect, data);
}
export function _ttw2_dect(data) {
  return axios.post(config.api.ttw2_dect, data);
}
export function _ttw3_dect(data) {
  return axios.post(config.api.ttw3_dect, data);
}
// ==========================锡伯文===========================
export function _xbw1_dect(data) {
  return axios.post(config.api.xbw1_dect, data);
}
export function _xbw2_dect(data) {
  return axios.post(config.api.xbw2_dect, data);
}
export function _xbw3_dect(data) {
  return axios.post(config.api.xbw3_dect, data);
}